{% extends "VozminoskiStoreBundle:Admin:layout.html.twig" %}
{% block content %}

<form action="{{ path('admin_color_update', { 'id': entity.id }) }}" method="post" {{ form_enctype(edit_form) }} class="form-horizontal">
    <fieldset>
        <legend>Product edit</legend>


        {{ form_errors(edit_form) }}
        <div class="control-group">
            {{ form_label(edit_form.name, 'Name',{ 'label_attr': {'class': 'control-label'} }) }}
            {{ form_errors(edit_form.name) }}
            <div class="controls">
                {{ form_widget(edit_form.name) }}
            </div>
        </div>

        <div class="control-group">
            {{ form_label(edit_form.code, 'Code',{ 'label_attr': {'class': 'control-label'} }) }}
            {{ form_errors(edit_form.code) }}
            <div class="controls">
                {{ form_widget(edit_form.code) }}
            </div>
        </div>

        <div class="control-group">
            {{ form_label(edit_form.order, 'Order',{ 'label_attr': {'class': 'control-label'} }) }}
            {{ form_errors(edit_form.order) }}
            <div class="controls">
                {{ form_widget(edit_form.order) }}
            </div>
        </div>

        <div class="control-group">
            {{ form_label(edit_form.is_active, 'Order',{ 'label_attr': {'class': 'control-label'} }) }}
            {{ form_errors(edit_form.is_active) }}
            <div class="controls">
                {{ form_widget(edit_form.is_active) }}
            </div>
        </div>






        {{ form_rest(edit_form) }}

        <button type="submit" class="btn btn-success">Save</button>
    </fieldset>
</form>

<div style="padding: 50px">
    <form action="{{ path('admin_color_delete', { 'id': entity.id }) }}" method="post">
        {{ form_widget(delete_form) }}
        <button type="submit" class="btn btn-danger">Delete</button>
    </form>

    <a href="{{ path('admin_color') }}" class="btn btn-primary">
        Back to the list
    </a>
</div>

{% endblock %}

